<template>
  <div class="app-menu">
    <app-menu-item
      v-for="(item, index) in menus"
      :key="item.value"
      :menu="item"
      :active="route.path == '/' + item.value"
      @click="selectMenu(item, index)"
    />
  </div>
</template>
<script setup>
import config from '@/config'

import home from '@/assets/menu/home.png'
import homeActive from '@/assets/menu/active/home.png'

import contact from '@/assets/menu/contact.png'
import contactActive from '@/assets/menu/active/contact.png'


const route = useRoute()
const router = useRouter()
const sotre = useAppStore()
const { menuIndex, selectMenu } = toRefs(sotre)

const menus = [
  { label: '环境', value: 'home', icon: home, activeIcon: homeActive }
]
</script>
<style lang="scss" scoped>
.app-menu {
  display: flex;
  align-items: center;
}
</style>
